<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		 <script>
		 	//var x=10;
			//console.log(x);
			//{
			//	var x=100;
			//	console.log(x);
			//}
			//console.log(x);
			//代码段中let第一变量作用域，代码段结束，里面的X也结束
			let x=10;
			console.log(x);
			{
				let x=100;
				console.log(x);
			}
			console.log(x);
			
			const pi=3.14;
			console.log(pi);
			//pi=3.141415;const定义常量
		 </script>
	</head>
	<body>
		<h3>es6新标准案例</h3>
	</body>
</html>
